#ifndef OFFSCREEN_SURFACE
#define OFFSCREEN_SURFACE

#include "glew.h"
#include "Logger.hpp"
#include <cassert>
#include <iostream>
#include <string>

class OffscreenSurface
{
public:
	OffscreenSurface();
	void bind();
	void unbind();
	
	GLuint createBuffer();
	GLuint createDepth();
	
	GLuint getDepth() const { return depth; }
	
	int getWidth() const { return m_windowWidth; }
	int getHeight() const { return m_windowHeight; }
	
	void intialize();
	
protected:
	GLuint fbo;
	GLuint depth;
	GLuint depthbuffer;
	GLuint nextAttachment;
	
	int m_windowWidth;
	int m_windowHeight;
};


#endif

